









exports.uploadFile = (req,res)=>{
    if(req.files == null){
        return res.output("no file uploaded",-1)
    }
    // file 由后文中 formData.append('file',file)的第一个参数定义,可自定义其他名称
    const file = req.files.file
    console.log(file)
    // file.mv("../public/uploads/"+file.name,err=>{
    //     if(err) return res.output(err,500)
    //     return res.output("upload success",0,{fileName:file.name,filePath:"uploads/"+file.name})
    // })
}